#!/usr/bin/env gnuplot
#绘制串口接收的数据


set key
set grid
 

# set title "sin cos"

# plot \
#     "t.txt" using 1 w l title "1" ,\
#     "t.txt" using 2 w l title "2" 


set title "CORDIC算法计算atan"
set xlabel "x"
set ylabel "y"
set zlabel "z"

set ztics 20

splot \
    "t.txt" using 1:2:3 w l title "cordic" ,\
    "t.txt" using 1:2:4 w l title "arctan" 
    
#quit
#pause 5 #等待4s
#refresh #刷新，重新绘制
#reread #读取数据显示
pause 60
exit
